From 93b9d17cce78dee2b5aa27f99a816cbee8daf568 Mon Sep 17 00:00:00 2001 From: "iap10@tetris.cl.cam.ac.uk" Date: Thu, 21 Apr 2005 00:11:07 +0000 Subject: [PATCH] bitkeeper revision 1.1348 (4266ef9bSWLiNFi-ZJ_TkK7jYaRikA) Truly round off the div result to get right PIT frequency for guest. Otherwise, the guest's idea of time drifts away from that of the host. Signed-off-by: Edwin Zhai Signed-off-by: Arun Sharma Signed-off-by: ian@xensource.com --- xen/include/xen/lib.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xen/include/xen/lib.h b/xen/include/xen/lib.h index fb809de82a..d80bc4a4c1 100644 --- a/xen/include/xen/lib.h +++ b/xen/include/xen/lib.h @@ -23,7 +23,7 @@ #define SWAP(_a, _b) \ do { typeof(_a) _t = (_a); (_a) = (_b); (_b) = _t; } while ( 0 ) -#define DIV_ROUND(x, y) (((x) + (y) - 1) / (y)) +#define DIV_ROUND(x, y) (((x) + (y) / 2) / (y)) #define reserve_bootmem(_p,_l) ((void)0) -- 2.30.2